home *** CD-ROM | disk | FTP | other *** search
/ Dr. Windows 3 / dr win3.zip / dr win3 / UTILITY1 / MSWSRC35.ZIP / METER / CNTL-DE.H < prev    next >
Text File  |  1992-06-11  |  2KB  |  57 lines

  1. /*****************************************************************
  2. Module name: Cntl-DE.H
  3. Programmer : Jeffrey M. Richter.
  4. *****************************************************************/
  5.  
  6. // This function should be called first in the ClassInfo
  7. // function to initialize the new control.
  8. HGLOBAL WINAPI ControlInfo (WORD wVersion, LPSTR szClass,
  9.    LPSTR szTitle);
  10.  
  11.  
  12.  
  13. // This function should be called repeatedly to add new control 
  14. // types to the structure returned by the ControlInfo function.  
  15. // This function should be called in the ClassInfo function.
  16. BOOL WINAPI AddControlType (HGLOBAL hGlbl, WORD wType,
  17.    WORD wWidth, WORD wHeight, DWORD dwStyle, LPSTR szDescr);
  18.  
  19.  
  20.  
  21. // This function displays the control's style dialog box and 
  22. // should be called from the ClassStyle function.
  23. int WINAPI ShowStyleDlg (HINSTANCE hInstance, LPCSTR szTemplate,
  24.    HWND hWndParent, DLGPROC fpDlgProc, LPARAM lParam,
  25.    HGLOBAL hGlblCtlStyle, LPFNSTRTOID lpfnStrToId,
  26.    LPFNIDTOSTR lpfnIdToStr);
  27.  
  28.  
  29. // This function should only be called from the ClassDlgFn
  30. // function.  It locks the memory block containing the CTLSTYLE
  31. // structure for the selected control and returns the FAR
  32. // address to that structure.
  33. LPCTLSTYLE WINAPI CtlStyleLock (HWND hDlg);
  34.  
  35.  
  36. // This function should only be called from the ClassDlgFn
  37. // function.  It unlocks the memory block containing the CTLSTYLE
  38. // structure for the selected control and returns whether the 
  39. // block was successfully unlocked.
  40. BOOL WINAPI CtlStyleUnlock (HWND hDlg);
  41.  
  42.  
  43. // This function should only be called from the ClassDlgFn
  44. // function.  It converts the ID value for the control into a 
  45. // identifier string and stores the string in the address passed
  46. // in.  The number of characters in the string is returned.
  47. WORD WINAPI GetIdString (HWND hDlg, LPSTR szId, WORD wIdMaxLen);
  48.  
  49.  
  50. // This function should only be called from the ClassDlgFn
  51. // function.  It converts an ID string value into its numeric 
  52. // equivalent and stores the numeric value in the CTLSTYLE 
  53. // structure for the control.  If the loword of the result is 0,
  54. // the ID is invalid, otherwise, the hiword contains the numeric
  55. // value of the ID.
  56. DWORD WINAPI SetIdValue (HWND hDlg, LPSTR szId);
  57.